1. Field of the Invention
The present invention relates to an image processing device and method for the same, and more particularly relates to an image processing device and method for the same that are capable of detecting a ground in color image data and eliminating this ground effectively.
2. Description of the Related Art
In recent years, along with the increasing popularity of digital cameras, cases are being seen in which information written upon a blackboard or whiteboard, or part of the information in a notice, advertising leaflet, magazine, or newspaper is being photographed with a digital camera, and the information is being recorded in this manner.
It is considered that the reason for this is that, with the enhancement of the performance of digital cameras, their resolution has increased, and moreover they are easily portable to an event location, so that it has become possible to photograph a photographic subject and to record the resulting information in an easy and simple manner.
In the past, when recording the information in a printed document such as an advertising leaflet or a magazine, a semi-fixed type scanner has been used, and in this case a uniform lighting (illumination) state is obtained.
However, when recording information with a digital camera, it is difficult always to obtain a uniform lighting state during photography, and unevenness is typically present in an image that has been photographed under such non-uniform lighting conditions, which is not desirable.
Furthermore, when photographing a paper manuscript or the like with a digital camera, the ground of the paper may also be photographed in the image data, so that it appears soiled, which is also not desirable.
When unevenness or blotchiness is present in color image data which has been photographed, it is difficult to eliminate such a ground in the image data, even by performing color copying or color scanning or the like.
As a related art technique for removing a ground in image data which has been photographed, an image processing device has been proposed, as disclosed in Japanese Patent Laid-Open Publication 2002-247363, which is capable of detecting the ground level for each area of a manuscript and of performing natural ground removing process, even in the case of a manuscript which exhibits blotchiness, such as when the ground level changes abruptly, as may happen with the ground of the image data for a manuscript which is pasted together or the like, or when the ground level continually varies.
It should be understood that, with the technique described in the above Japanese Patent Application Laid-Open No. 2002-247363, a method is proposed, as ground removing process for a manuscript which is pasted together, of changing abruptly the ground level which is detected; and further a method is proposed, as ground removing process for a manuscript which exhibits blotchiness, of performing adjustment so that the ground level varies gradually in a continuous fashion.
However, with the technique described in the above Japanese Patent Application Laid-Open No. 2002-247363, since the process is performed while only paying attention to the density value of the image data of the manuscript, correspondence has no longer been maintained of the individual pixels with the color image data expressed by the values of the channels of the color space.
Thus, for example, in the case of color image data which is expressed by an RGB color space, when the invention described in the above Japanese Patent Application Laid-Open No. 2002-247363 is applied to each of the respective channels R, G, and B, the color matching changes, and inconveniences such as color oozing and the like arise.